<!DOCTYPE>
<html>
<head>
    <meta charset="utf-8">
    <title>隐患</title>
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1, user-scalable=no">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link rel="stylesheet" type="text/css" href="css/public.css">
    <link rel="stylesheet" type="text/css" href="css/style.css">
    <script src="js/mui.min.js"></script>
    <script src="js/jquery.js"></script>
    <script src="js/mui.picker.min.js"></script>
    <script src="js/form.js"></script>
    <script>
        $(function ()
        {
            var arr = [];
            //全选
            var checkLength = $("input[name='pick_fname']:checked").length;
            $("#checkAll").click(function(){
                if($('#checkAll').is(':checked')){
                    $(".up_pick_nav :checkbox").prop("checked", true);
                    $('.up_screen_total font').text(4)
                }else{
                    $(".up_pick_nav :checkbox").prop("checked", false);
                    $('.up_screen_total font').text(0)
                }
            });
            $("input[name='pick_fname']").click(function() {
                var checkLength = $("input[name='pick_fname']:checked").length;
                $('.up_screen_total font').text(checkLength);
            });
            $(".up_screen_total").click(function(){
                var strIds=new Array();//声明一个存放id的数组
                $("input[name='pick_fname']").each(function (i,d){
                    if (d.checked) {
                        strIds.push(d.value);
                    }
                });
                if(strIds.length<1)
                    alert("您没有选中项!");
                else{
                    //var ids = new Object();
                    //var ids=strIds.join(",");
                    localStorage.setItem("key",strIds);
                    location.href="selected.html";
                }
            });
        });
    </script>
</head>
<body>
<!--加载动画start-->
<div class="load" id="load">
    <div class="loading_bod" onclick="closeLoading()"></div>
    <div class="loading"><img src="images/loading.png" /></div>
</div>
<!--加载动画end-->
<div class="up_list_content">
    <!--搜索start-->
    <div class="up_search">
        <input type="text" />
        <span class="up_sear_button" onclick="openLoading();"></span>
    </div>
    <!--搜索end-->
    <!--选择复查人start-->
    <div class="up_pick_second_list">
        <div class="up_pick_all">
            <input type="checkbox" id="checkAll" name="all_fname" />
            <label for='' class="checkbox-label"></label>
            <span class="up_pick_fname">全选</span>
            <div class="clear_both"></div>
        </div>
        <ul class="up_pick_nav">
            <li>
                <input type="checkbox" id="checkAll" name="pick_fname" value="俊雄1" />
                <label for='' class="checkbox-label"></label>
                <span class="up_pick_photo">俊雄</span>
                <span class="up_pick_second_fname">1姜俊雄</span>
                <div class="clear_both"></div>
            </li>
            <li>
                <input type="checkbox" id="checkAll" name="pick_fname" value="俊雄2" />
                <label for='' class="checkbox-label"></label>
                <span class="up_pick_photo">俊雄</span>
                <span class="up_pick_second_fname">2姜俊雄</span>
                <div class="clear_both"></div>
            </li>
            <li>
                <input type="checkbox" id="checkAll" name="pick_fname" value="俊雄3" />
                <label for='' class="checkbox-label"></label>
                <span class="up_pick_photo">俊雄</span>
                <span class="up_pick_second_fname">3姜俊雄</span>
                <div class="clear_both"></div>
            </li>
            <li>
                <input type="checkbox" id="checkAll" name="pick_fname" value="俊雄4" />
                <label for='' class="checkbox-label"></label>
                <span class="up_pick_photo">俊雄</span>
                <span class="up_pick_second_fname">4姜俊雄</span>
                <div class="clear_both"></div>
            </li>
        </ul>
    </div>
    <!--选择复查人end-->
    <!--已选择总人数start-->
    <div class="up_screen_total"><span class="up_select_icon"></span><span class="up_select_jt">已选择<font>0</font>人</span></div>
    <!--已选择总人数end-->
</div>
<!--提交按钮start-->
<div class="up_screen_button">
    <input type="button" value="确定">
</div>
<!--提交按钮end-->
</body>
</html>